Digital data processing systems typically include data storage devices, for example, multi-disk disk drives. Data is recorded on the disks in concentric tracks. The tracks are divided into sectors, and each sector is further divided into several sections including, for example, a header section and a data section. Data is recorded in (written) or retrieved from (read) the data portions of the sectors while synchronization information and address information, that is, disk surface number, track number and sector number, are stored in the header sections.
Data is read from or written to the disks using read/write heads. Each head is associated with a particular disk surface or portion of a disk surface. As the disks rotate under the heads, data is, for example, read from a particular sector when the associated head is over the data portion of that sector.
To begin a read or write operation the appropriate head is moved to the track containing the selected sector. Unless the head was used in the immediately preceding read or write operation, the head, or more specifically the timer and clocks associated with the read/write operation, must then be synchronized to the disk so that the sector addresses rotating under the head can be read. Once it is synchronized to the header synchronization information, it locates the selected sector by reading the sector addresses. When the sector is located the head locates the start of the data section of the sector and it performs the read or write operation. If, for example, during a read operation the start of the data section is not exactly located, inappropriate information read from the disk may be interpreted as data.
The data read from the disk is typically in encoded form. Prior to recording the data is encoded using error correction codes (ECC's). Encoding the data avoids losing it if it becomes corrupted due to a defect in the disk or noise signals in the read or write channels, either of which may cause the data signal to be misinterpreted. The result of misinterpreting the data signal is erroneous data. The error correction codes ("ECC's") are employed to, as the name implies, correct the erroneous data.
Before a string of data symbols is written to a disk, it is mathematically encoded to form ECC symbols. The ECC symbols are then appended to the data string to form code words--data symbols plus ECC symbols--and the code words are written to or stored on the disks. When data is to be read from the disks, the code words containing the data symbols are retrieved from the disks and mathematically decoded. During decoding any errors in the data are detected and, if possible, corrected through manipulation of the ECC symbols [For a detailed description of decoding see Peterson and Weldon, Error Correction Codes, 2d Edition, MIT Press, 1972].
Stored digital data can contain multiple independent errors. One of the most effective types of ECC used for the correction of multiple errors is a Reed-Solomon code [For a detailed description of Reed-Solomon codes, see Peterson and Weldon, Error Correction Codes]. To correct multiple errors in strings of data symbols, Reed-Solomon codes efficiently and effectively utilize the various mathematical properties of sets of symbols known as Galois Fields, represented "GF(P.sup.q)", where "P" is a prime number and "q" can be thought of as the number of digits, base P, in each element or symbol in the field. "P" usually has the value 2 in digital computer applications and, therefore, "q" is the number of bits in each symbol.
The size of a Galois Field is P.sup.q symbols, that is, the field has P.sup.q elements. Thus if GF(2.sup.8) is the selected field, there are 2.sup.8 or 256 elements and each element of the field is an eight-bit symbol. The non-zero elements are of the form .alpha..sup.i, where ".alpha." is a primitive element of the field and 0.ltoreq.i.ltoreq.P.sup.q -1. Thus each element is a multiple of .alpha.. Galois Fields are finite fields, that is, they have a finite number of elements. Thus for each .alpha..sup.k, k&gt;p.sup.q, there is an .alpha..sup.j, j.ltoreq.P.sup.q -1, where .alpha..sup.k 32 .alpha..sup.j.
Error detection and correction techniques for Reed-Solomon ECC's are well known. Id. One such technique begins with again encoding the code word data to generate ECC symbols and then comparing these ECC symbols with the ECC symbols in the code word, i.e. the ECC symbols generated by the pre-storage encoding of the data, to detect any errors in the retrieved data. [For a detailed discussion of this error detection technique, see U.S. Pat. No. 4,413,339 issued to Riggle and Weng].
The comparison of the two sets of ECC symbols is made by exclusive OR'ing ("XOR'ing") them. If there are no errors in the retrieved data, the XOR'ing will produce a string of symbols containing only zeros. If there are errors in the retrieved data, the result of the XOR'ing will be non-zero and error correction will be performed, if possible. If the number of non-zero symbols which result from the XOR'ing is less than the number of errors the code is designed to correct, all the errors are in the ECC symbols and no error correction is required. If the number of non-zero resulting symbols is equal to or greater than the number of errors the code is designed to correct, the data contains one or more errors and error correction is then performed.
In order to correct the data errors, the locations and the magnitudes or "values" of the errors must be determined. The first step in determining the error locations and the error values is to form error syndrome equations from the results of the XOR'ing of the ECC symbols. [For a detailed discussion of the generation of the error syndromes refer to U.S. Pat. No. 4,413,339 issued to Riggle and Weng]. The error syndromes are then used to generate polynomials which, when evaluated, will identify the location and the value of each of the errors.
Alternatively the error syndromes may be formed using the entire retrieved code word. This avoids the steps of re-encoding the retrieved data and comparing the ECC symbols with the retrieved ECC symbols. However, error syndromes will be generated for every code word, even those without errors, although in the latter case the syndromes will be identically zero. Where there are errors, i.e. the error syndromes are not zero, the syndromes are then used to locate and correct any errors in exactly the same manner as the syndromes formed from the results of the XOR'ing of the ECC symbols. The choice between these two arrangements may, for example, depend on whether the syndromes are generated in software or hardware.
The calculation of the values of the errors is necessarily dependent on their locations. Typically, the error locations are calculated first by using the error syndromes to generate an error locator polynomial .delta.(x). The solutions or roots of the equation, .delta.(x)=0, designate the locations of the errors. The roots, x.sub.r, are then substituted into an error evaluator polynomial .PHI.(x) and the polynomial is evaluated. The results are then divided by the corresponding values of the first derivative, .delta.'(x.sub.r), of the error locator polynomial to provide the values of the errors. Once both the error locations and the corresponding error values are known, the data can then be corrected.
Reed-Solomon codes are cyclic codes, that is, if v=c.sub.1 c.sub.2 c.sub.3. . . c.sub.z-i c.sub.z is a code word, where c.sub.a is an element of the Galois Field used to encode the data and z=P.sup.q -1, then v'=c.sub.z c.sub.1 c.sub.2 c.sub.3. . . c.sub.z-1 is also a code word. If a shortened code is used, it is likely that the code words will appear cyclic, that is, if z=00000z.sub.1 z.sub.2 z.sub.3. . . z.sub.q 0 is a code word, then z'=000000z.sub.1 z.sub.2 z.sub.3. . . z.sub.q is a code word. However, z"=z.sub.q 000000z.sub.1 z.sub.2 z.sub.3. . . z.sub.q-1 is not a code word in the shortened code because the first term of z" is non-zero.
Thus if the boundaries of a code word are misinterpreted, for example, during a read operation, and the operation starts one or two complete symbols beyond the beginning of the code word and then appends one or two symbols from the beginning of the next code word to the end, the result is likely to be another code word. This means that if the head is not precisely synchronized, for example, to the start of the data section of a sector the code word read from the disk may contain only a portion of the data recorded in the sector and thus the data may be inaccurately interpreted by the data processing system. If, however, the synchronization is off by less than a complete symbol, the code will indicate the mis-synchronization by detecting a number of errors, typically more errors than the code is designed to correct. Thus it is desirable to encode the data such that a one or more full symbol mis-synchronization is indicated by the code.